import django_filters
from rest_framework.filters import FilterSet

from course.models import Course


class CourseFilterSet(FilterSet):
    """
    学生筛选器
    """
    e_course_name = django_filters.CharFilter(lookup_expr='icontains')
    c_course_name = django_filters.CharFilter(lookup_expr='icontains')
    course_group = django_filters.NumberFilter()

    class Meta:
        model = Course
        fields = "__all__"

